<!DOCTYPE html>
<html lang="zh-cn">
    <head>
        <meta charset="UTF-8"/>
        <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
        <title>弹性盒子兼容性</title>
        <style>
            .flexBox{
                display:-webkit-box;/* OLD - iOS 6-, Safari 3.1-6 */ /* Chrome 4+, Safari 3.1, iOS Safari 3.2+ */ 
                display:-moz-box;/* OLD - Firefox 19-  */
                display: -ms-flexbox;      /* TWEENER - IE 10 */
                display: -webkit-flex;     /* NEW - Chrome */ /* Chrome 21+, Safari 6.1+, iOS Safari 7+, Opera 15/16 */
                display: flex;             /* NEW, Spec - Opera 12.1, Firefox 20+ *//* Chrome 29+, Firefox 22+, IE 11+, Opera 12.1/17/18, Android 4.4+ */ 
            }
            /*垂直居中*/
            .vm{
                align-items:center;
            }
            /*align-items:flex-start | flex-end | center | baseline | stretch 等五个值*/
            /*水平居中*/
            .hc{
                justify-content:center;
            }
            /*justify-content:flex-start | flex-end | center | space-between | space-around 等五个值*/
            /*多轴垂直居中*/
            .vm-many{
                align-content:center;
            }
            /*align-content:flex-start | flex-end | center | space-around | space-between | stretch 等六个值*/
            .flex-item{
                width: 200px;
                height: 200px;
                margin: 10px;
                background-color: #f00;
            }
        </style>
    </head>
    <body>
        <h1>弹性盒子兼容性-CSS3 弹性盒子(Flex Box)</h1>
        <p>来源:<a href="http://www.runoob.com/css3/css3-flexbox.html"></a>http://www.runoob.com/css3/css3-flexbox.html</p>
        <div class="flexBox vm hc">
            <div class="flex-item">早点休息</div>
            <div class="flex-item">你老是流鼻涕，免疫力下降，你还不早点睡</div>
        </div>
    </body>
</html>